<template>
    <div class="w-full h-full flex flex-col">
        <div class="w-full flex flex-row justify-between">
            <div class="flex flex-row   w-w1/5">
            </div>
            <el-button type="primary" class=" bg-cmain_hover ml-w10" icon="el-icon-plus"
                @click="action_show_dialog">添加管理员</el-button>
        </div>
        <div class="w-full h-full mt-w20 ">
            <el-table :data="s_admin.list_admin" stripe style="width: 100%; " height="800">
                <el-table-column type="index" label="序号" min-width="5%">
                </el-table-column>
                <el-table-column prop="sAccount" label="账号" min-width="15%">
                </el-table-column>
                <el-table-column prop="roleName" label="角色" min-width="15%">
                </el-table-column>
                <el-table-column label="操作" min-width="10%">
                    <template slot-scope="scope">
                        <el-button type="text" @click="action_edit_data(scope.row)">
                            编辑
                        </el-button>
                        <el-button type="text" :class="scope.row.iStatus == 0 ? ' text-cmain_shallow' : ' text-calt'" @click="action_operate_data(scope.row)">
                            {{ scope.row.iStatus == 0 ? "解冻" : "冻结" }}
                        </el-button>
                        <el-button type="text" class=" text-cwarn" @click="action_del_data(scope.row)" >
                            删除
                        </el-button>
                    </template>
                </el-table-column>
            </el-table>
        </div>
        <UiDialogAddAdmin :data="s_admin.m_admin" :is_showDialog="dialog_add_admin"
            @nydialog_closed="dialog_add_role = false" @nydialog_submit="action_add_admin">
        </UiDialogAddAdmin>
    </div>
</template>

<script src="./Index.ts"></script>
<style src="./Index.less" lang="less" scoped></style>
